﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="newLeft.aspx.cs" Inherits="Moral_Teacher_RuleSettings_newLeft" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">


<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
    <title>无标题页</title>
     <link href="../../Common/css/main.css" rel="stylesheet" type="text/css" />
    <style type="text/css">
        .noneClick {
            cursor: default;
        }
    </style>

    <script type="text/javascript" src="../../Common/js/jquery.js"></script>

    <script type="text/javascript" src="../../Common/js/common.js"></script>
    
    <script type="text/javascript">
      /**
            导航单项汇总
        */
        function leftNavEvalItems(obj, evalID) {
            removeActiveStyle();
            obj.parentNode.className = "active";
             parent.frames["mainFrame"].location.href = "PersonSummary/Report.aspx?ID="+evalID;
        
        }
        
        /**
            导航个人查询
        */
        function leftNav(obj, nav) {
            if(nav == 0 || nav == 3 || nav == 4)
            {
                removeActiveStyle();
                obj.parentNode.className = "active";
            }
                
            switch(nav) {
                case 0:
                    {
                        parent.frames["mainFrame"].location.href = "SettingEvalDefault.aspx";
                        document.getElementById('li2').style.display ="block";
                        document.getElementById('li3').style.display ="block";
                        break;
                    }
                case 1:
                  //  parent.frames["mainFrame"].location.href = "ReviewEval.aspx";
                  var historyId= parent.frames["mainFrame"].currHistoryId;
                  var evalType = parent.frames["mainFrame"].currEvalType;
                  if(historyId != null  && evalType!=null && historyId > 0)
                  {
                    var url;
                    if(evalType==1)
                    {
                        url = "ReviewEval.aspx?historyId="+historyId+"&download=0";
                    }
                    else
                    {
                        url = "ReviewClassEval.aspx?historyId="+historyId+"&download=0";
                    }
                    window.open (url);
                  }
                  else
                  {
                    parent.frames["mainFrame"].showMassgeBox("提示",'请您先选择要评估规则',1,null);
                  }
//                  
                    
                    break;
                case 2:
                    var historyId= parent.frames["mainFrame"].currHistoryId;
                    var evalType = parent.frames["mainFrame"].currEvalType;
                  if(historyId != null && historyId >0)
                  {
                    var url;
                    if(evalType==1)
                    {
                        url = "ReviewEval.aspx?historyId="+historyId+"&download=1";
                    }
                    else
                    {
                        url = "ReviewClassEval.aspx?historyId="+historyId+"&download=1";
                    }
//                    var url = "ReviewTeacherEval.aspx?historyId="+historyId+"&download=1";
                    document.getElementById("downloadf").src = url;
                  }
                  else
                  {
                    parent.frames["mainFrame"].showMassgeBox("提示",'请您先选择要预览的学分记录',1,null);
                  }
                    break; 

                
                default : break;
            }
        }
                
        /**
            移除active样式
        */
        function removeActiveStyle() {
            var liList = document.getElementsByTagName("li");
            for (var i=0; i<liList.length; i++) {
                liList[i].className = "";
            }
        }
        
        window.onload = function() {
            document.getElementById('li1').all[0].click();
            //parent.frames["mainFrame"].location.href = "SettingEvalDefault.aspx";
        }
        

    </script>
    
</head>
<body>
   <form id="form1" runat="server">
        <div class="leftWarp">
            <div class="menuBody">
                <div class="menuList">

                        <h2>
                            评 价 设 置</h2>
                        <ul>

                                <li id="li1"><a href="#"  onclick="leftNav(this, 0)">&nbsp;&nbsp;&nbsp;&nbsp;编辑评价</a></li>

                                <li id="li2"><a href="#" onclick="leftNav(this, 1)">&nbsp;&nbsp;&nbsp;&nbsp;预览评价</a></li>

                                <li id="li3"><a href="#" onclick="leftNav(this, 2)">&nbsp;&nbsp;&nbsp;&nbsp;下载评价</a></li>


                        </ul>

                </div>
            </div>
        </div>
        
    <div id="upInputPop" class="layoutWarp" style="display: none">
        <iframe src=""  id="downloadf" style="height: 80%;width: 95%;overflow-y:auto;overflow-x:none;" frameborder="0"   ></iframe>
    </div>

    </form>
</body>
</html>
